{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 1,
   "metadata": {
    "collapsed": true
   },
   "outputs": [],
   "source": [
    "import numpy as np\n",
    "import pandas as pd\n",
    "\n",
    "from sklearn.metrics import confusion_matrix\n",
    "from sklearn.metrics import roc_auc_score, auc\n",
    "from sklearn.metrics import precision_recall_curve\n",
    "from sklearn.metrics import classification_report\n",
    "from collections import Counter\n",
    "import re\n",
    "from tqdm import trange"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "metadata": {
    "collapsed": true
   },
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>miRNA</th>\n",
       "      <th>miRBase Update ID</th>\n",
       "      <th>disease</th>\n",
       "      <th>Cancer Subtype</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>hsa-miR-106a</td>\n",
       "      <td>hsa-miR-106a-5p</td>\n",
       "      <td>lymphoma</td>\n",
       "      <td>B cell lymphoma</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>hsa-let-7g</td>\n",
       "      <td>hsa-let-7g-5p</td>\n",
       "      <td>lymphoma</td>\n",
       "      <td>B cell lymphoma</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>hsa-miR-17-5p</td>\n",
       "      <td>hsa-miR-17-5p</td>\n",
       "      <td>lymphoma</td>\n",
       "      <td>B cell lymphoma</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>hsa-let-7f</td>\n",
       "      <td>hsa-let-7f-5p</td>\n",
       "      <td>lymphoma</td>\n",
       "      <td>B cell lymphoma</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>hsa-let-7a</td>\n",
       "      <td>hsa-let-7a-5p</td>\n",
       "      <td>lymphoma</td>\n",
       "      <td>B cell lymphoma</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>98742</th>\n",
       "      <td>hsa-mir-34a</td>\n",
       "      <td>NaN</td>\n",
       "      <td>Glioblastoma</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>98747</th>\n",
       "      <td>hsa-mir-15b</td>\n",
       "      <td>NaN</td>\n",
       "      <td>Stomach Neoplasms</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>98748</th>\n",
       "      <td>hsa-mir-16-1</td>\n",
       "      <td>NaN</td>\n",
       "      <td>Stomach Neoplasms</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>98749</th>\n",
       "      <td>hsa-mir-16-2</td>\n",
       "      <td>NaN</td>\n",
       "      <td>Stomach Neoplasms</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>98755</th>\n",
       "      <td>hsa-mir-449a</td>\n",
       "      <td>NaN</td>\n",
       "      <td>Prostatic Neoplasms</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>59765 rows × 4 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "               miRNA miRBase Update ID              disease   Cancer Subtype\n",
       "0       hsa-miR-106a   hsa-miR-106a-5p             lymphoma  B cell lymphoma\n",
       "1         hsa-let-7g     hsa-let-7g-5p             lymphoma  B cell lymphoma\n",
       "2      hsa-miR-17-5p     hsa-miR-17-5p             lymphoma  B cell lymphoma\n",
       "3         hsa-let-7f     hsa-let-7f-5p             lymphoma  B cell lymphoma\n",
       "4         hsa-let-7a     hsa-let-7a-5p             lymphoma  B cell lymphoma\n",
       "...              ...               ...                  ...              ...\n",
       "98742    hsa-mir-34a               NaN        Glioblastoma               NaN\n",
       "98747    hsa-mir-15b               NaN   Stomach Neoplasms               NaN\n",
       "98748   hsa-mir-16-1               NaN   Stomach Neoplasms               NaN\n",
       "98749   hsa-mir-16-2               NaN   Stomach Neoplasms               NaN\n",
       "98755   hsa-mir-449a               NaN  Prostatic Neoplasms              NaN\n",
       "\n",
       "[59765 rows x 4 columns]"
      ]
     },
     "execution_count": 2,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "database_data = pd.read_csv('database_file汇总.csv').drop_duplicates()\n",
    "database_data"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "metadata": {},
   "outputs": [],
   "source": [
    "def new_MDA(results_df, task, balanced = True):\n",
    "    new_MDA = results_df[results_df['y_true'] == 0][results_df['y_pred'] == 1]\n",
    "    if balanced:\n",
    "        new_MDA.to_csv(task + '_balanced_new_MDA.csv')\n",
    "    else:\n",
    "        new_MDA.to_csv(task + '_unbalanced_new_MDA.csv')\n",
    "        \n",
    "    new_MDA_simplied = new_MDA[['miRNA_y', 'disease_y', 'y_prob']]\n",
    "\n",
    "    temp = []\n",
    "    for item in new_MDA_simplied['disease_y'].tolist():\n",
    "        item = item.replace(\"['\",'').replace(\"']\", \"\")\n",
    "        temp.append(item)\n",
    "    new_MDA_simplied['disease_newMDA'] = temp\n",
    "    \n",
    "    return new_MDA, new_MDA_simplied"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "metadata": {},
   "outputs": [],
   "source": [
    "def database_data_miRNA_in_newMDA_results(database_data, new_MDA_simplied):\n",
    "    database_data_miRNA_in_results = database_data[database_data['miRNA'].isin(new_MDA_simplied['miRNA_y'])]\n",
    "    database_data_miRNA_in_results_2 = database_data[database_data['miRBase Update ID'].isin(new_MDA_simplied['miRNA_y'])]\n",
    "    if database_data_miRNA_in_results_2.shape[0] != 0:\n",
    "        print('miRBase Update ID shoud be used!!!!!!')\n",
    "        database_data_miRNA_in_results = pd.concat([database_data_miRNA_in_results, ], axis = 0)\n",
    "    return database_data_miRNA_in_results"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 5,
   "metadata": {
    "scrolled": true
   },
   "outputs": [],
   "source": [
    "def newMDA_in_database(new_MDA_simplied, database_data_miRNA_in_results):\n",
    "    \n",
    "    for i in trange(new_MDA_simplied.shape[0]):\n",
    "        print('-------------------------{}-th new MDA--------------------------------------------'.format(i))\n",
    "        miRNA = new_MDA_simplied.iloc[i]['miRNA_y']\n",
    "        disease_of_miRNA = new_MDA_simplied.iloc[i]['disease_newMDA']\n",
    "        print('miRNA = {}  ||  disease_of_miRNA = {}'.format(miRNA, disease_of_miRNA))\n",
    "        disease_of_miRNA = disease_of_miRNA.split(' ')\n",
    "        database_data_of_miRNA = database_data_miRNA_in_results[database_data_miRNA_in_results['miRNA'] == miRNA]\n",
    "\n",
    "        for str_ in disease_of_miRNA:\n",
    "            res = database_data_of_miRNA.loc[database_data_of_miRNA['disease'].str.contains(str_)]\n",
    "            print(str_, '--> ', res.values, '\\n')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 6,
   "metadata": {
    "collapsed": true
   },
   "outputs": [],
   "source": [
    "def run(task, database_data):\n",
    "    results = pd.read_csv(task + '_balanced_case_study_0.csv', index_col = 0)\n",
    "    new_MDA_origin, new_MDA_simplied = new_MDA(results, task, True)\n",
    "    database_data_miRNA_in_results = database_data_miRNA_in_newMDA_results(database_data, new_MDA_simplied)\n",
    "    newMDA_in_database(new_MDA_simplied, database_data_miRNA_in_results)\n",
    "    return results, new_MDA, new_MDA_simplied, database_data_miRNA_in_results"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 7,
   "metadata": {},
   "outputs": [
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "/home/chujunyi/anaconda3/envs/python36/lib/python3.6/site-packages/ipykernel_launcher.py:2: UserWarning: Boolean Series key will be reindexed to match DataFrame index.\n",
      "  \n",
      "/home/chujunyi/anaconda3/envs/python36/lib/python3.6/site-packages/ipykernel_launcher.py:14: SettingWithCopyWarning: \n",
      "A value is trying to be set on a copy of a slice from a DataFrame.\n",
      "Try using .loc[row_indexer,col_indexer] = value instead\n",
      "\n",
      "See the caveats in the documentation: http://pandas.pydata.org/pandas-docs/stable/user_guide/indexing.html#returning-a-view-versus-a-copy\n",
      "  \n",
      " 13%|█▎        | 10/77 [00:00<00:01, 66.69it/s]"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "-------------------------0-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-324  ||  disease_of_miRNA = Vascular Calcification\n",
      "Vascular -->  [] \n",
      "\n",
      "Calcification -->  [] \n",
      "\n",
      "-------------------------1-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-371a  ||  disease_of_miRNA = Vascular Calcification\n",
      "Vascular -->  [] \n",
      "\n",
      "Calcification -->  [] \n",
      "\n",
      "-------------------------2-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-548c  ||  disease_of_miRNA = Uterine Cervical Neoplasms\n",
      "Uterine -->  [] \n",
      "\n",
      "Cervical -->  [] \n",
      "\n",
      "Neoplasms -->  [['hsa-mir-548c' nan 'Breast Neoplasms' nan]\n",
      " ['hsa-mir-548c' nan 'Ovarian Neoplasms' nan]\n",
      " ['hsa-mir-548c' nan 'Rectal Neoplasms' nan]] \n",
      "\n",
      "-------------------------3-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-640  ||  disease_of_miRNA = Skin Neoplasms\n",
      "Skin -->  [] \n",
      "\n",
      "Neoplasms -->  [['hsa-mir-640' nan 'Gastric Neoplasms' nan]\n",
      " ['hsa-mir-640' nan 'Stomach Neoplasms' nan]] \n",
      "\n",
      "-------------------------4-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-10b  ||  disease_of_miRNA = Sepsis\n",
      "Sepsis -->  [] \n",
      "\n",
      "-------------------------5-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-300  ||  disease_of_miRNA = Sepsis\n",
      "Sepsis -->  [] \n",
      "\n",
      "-------------------------6-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-15a  ||  disease_of_miRNA = Salivary Gland Neoplasms\n",
      "Salivary -->  [['hsa-mir-15a' nan 'Salivary Gland Neoplasms' nan]] \n",
      "\n",
      "Gland -->  [['hsa-mir-15a' nan 'Salivary Gland Neoplasms' nan]] \n",
      "\n",
      "Neoplasms -->  [['hsa-mir-15a' nan 'Pituitary Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Prostate Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Kidney Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Breast Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Neoplasms [unspecific]' nan]\n",
      " ['hsa-mir-15a' nan 'Hematologic Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Gastric Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Colon Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Laryngeal Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Head And Neck Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Lung Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Myeloproliferative Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Pancreatic Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Salivary Gland Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Bladder Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Esophageal Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Prostatic Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Head and Neck Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Colonic Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Urinary Bladder Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Neoplasms' nan]] \n",
      "\n",
      "-------------------------7-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-589  ||  disease_of_miRNA = Salivary Gland Neoplasms\n",
      "Salivary -->  [] \n",
      "\n",
      "Gland -->  [] \n",
      "\n",
      "Neoplasms -->  [['hsa-mir-589' nan 'Gastric Neoplasms' nan]] \n",
      "\n",
      "-------------------------8-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-378c  ||  disease_of_miRNA = Renal Insufficiency\n",
      "Renal -->  [['hsa-mir-378c' nan 'Carcinoma, Renal Cell' nan]] \n",
      "\n",
      "Insufficiency -->  [] \n",
      "\n",
      "-------------------------9-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-296  ||  disease_of_miRNA = Renal Insufficiency\n",
      "Renal -->  [] \n",
      "\n",
      "Insufficiency -->  [] \n",
      "\n",
      "-------------------------10-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-2355  ||  disease_of_miRNA = Psoriasis\n",
      "Psoriasis -->  [] \n",
      "\n",
      "-------------------------11-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-641  ||  disease_of_miRNA = Papilary thyroid carcinoma\n",
      "Papilary -->  [] "
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      " 31%|███       | 24/77 [00:00<00:00, 56.74it/s]"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "\n",
      "\n",
      "thyroid -->  [] \n",
      "\n",
      "carcinoma -->  [] \n",
      "\n",
      "-------------------------12-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-320d  ||  disease_of_miRNA = Pancreatic Neoplasms\n",
      "Pancreatic -->  [] \n",
      "\n",
      "Neoplasms -->  [['hsa-mir-320d' nan 'Breast Neoplasms' nan]] \n",
      "\n",
      "-------------------------13-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-503  ||  disease_of_miRNA = Ovary Syndrome\n",
      "Ovary -->  [] \n",
      "\n",
      "Syndrome -->  [['hsa-mir-503' nan 'Nephrotic Syndrome' nan]] \n",
      "\n",
      "-------------------------14-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-561  ||  disease_of_miRNA = Osteoporosis\n",
      "Osteoporosis -->  [] \n",
      "\n",
      "-------------------------15-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-647  ||  disease_of_miRNA = Osteoarthritis\n",
      "Osteoarthritis -->  [] \n",
      "\n",
      "-------------------------16-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-1181  ||  disease_of_miRNA = Oligodendroglioma\n",
      "Oligodendroglioma -->  [] \n",
      "\n",
      "-------------------------17-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-922  ||  disease_of_miRNA = Nevus, Pigmented\n",
      "Nevus, -->  [] \n",
      "\n",
      "Pigmented -->  [] \n",
      "\n",
      "-------------------------18-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-664  ||  disease_of_miRNA = Neurodegenerative Diseases\n",
      "Neurodegenerative -->  [] \n",
      "\n",
      "Diseases -->  [] \n",
      "\n",
      "-------------------------19-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-191  ||  disease_of_miRNA = Nephrosclerosis\n",
      "Nephrosclerosis -->  [] \n",
      "\n",
      "-------------------------20-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-431  ||  disease_of_miRNA = Myocytes, Cardiac\n",
      "Myocytes, -->  [] \n",
      "\n",
      "Cardiac -->  [] \n",
      "\n",
      "-------------------------21-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-136  ||  disease_of_miRNA = Myocardium\n",
      "Myocardium -->  [] \n",
      "\n",
      "-------------------------22-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-637  ||  disease_of_miRNA = Multiple Sclerosis\n",
      "Multiple -->  [] \n",
      "\n",
      "Sclerosis -->  [] \n",
      "\n",
      "-------------------------23-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-449b  ||  disease_of_miRNA = Mouth Neoplasms\n",
      "Mouth -->  [] \n",
      "\n",
      "Neoplasms -->  [['hsa-mir-449b' nan 'Prostate Neoplasms' nan]\n",
      " ['hsa-mir-449b' nan 'Neoplasms [unspecific]' nan]\n",
      " ['hsa-mir-449b' nan 'Liver Neoplasms' nan]\n",
      " ['hsa-mir-449b' nan 'Gastric Neoplasms' nan]\n",
      " ['hsa-mir-449b' nan 'Salivary Gland Neoplasms' nan]\n",
      " ['hsa-mir-449b' nan 'Ovarian Neoplasms' nan]\n",
      " ['hsa-mir-449b' nan 'Bladder Neoplasms' nan]\n",
      " ['hsa-mir-449b' nan 'Stomach Neoplasms' nan]] \n",
      "\n",
      "-------------------------24-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-769  ||  disease_of_miRNA = Mastocytosis, Systemic\n",
      "Mastocytosis, -->  [] \n",
      "\n",
      "Systemic -->  [] \n",
      "\n",
      "-------------------------25-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-654  ||  disease_of_miRNA = Lymphoma, Large-Cell, Anaplastic\n",
      "Lymphoma, -->  [] \n",
      "\n",
      "Large-Cell, -->  [] \n",
      "\n",
      "Anaplastic -->  [] \n",
      "\n",
      "-------------------------26-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-513c  ||  disease_of_miRNA = Lymphoma, Extranodal NK-T-Cell\n",
      "Lymphoma, -->  [] \n",
      "\n",
      "Extranodal -->  [] \n",
      "\n",
      "NK-T-Cell -->  [] \n",
      "\n",
      "-------------------------27-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-601  ||  disease_of_miRNA = Lupus Erythematosus, Systemic\n",
      "Lupus -->  [['hsa-mir-601' nan 'Lupus Vulgaris' nan]] \n",
      "\n",
      "Erythematosus, -->  [] \n",
      "\n",
      "Systemic -->  [] \n",
      "\n",
      "-------------------------28-th new MDA--------------------------------------------"
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "\r",
      " 39%|███▉      | 30/77 [00:00<00:00, 57.54it/s]"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "\n",
      "miRNA = hsa-mir-1827  ||  disease_of_miRNA = Lupus Erythematosus, Systemic\n",
      "Lupus -->  [] \n",
      "\n",
      "Erythematosus, -->  [] \n",
      "\n",
      "Systemic -->  [] \n",
      "\n",
      "-------------------------29-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-582  ||  disease_of_miRNA = Lung Neoplasms\n",
      "Lung -->  [['hsa-mir-582' nan 'Lung Neoplasms' nan]] \n",
      "\n",
      "Neoplasms -->  [['hsa-mir-582' nan 'Lung Neoplasms' nan]\n",
      " ['hsa-mir-582' nan 'Prostate Neoplasms' nan]] \n",
      "\n",
      "-------------------------30-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-151a  ||  disease_of_miRNA = Lung Diseases\n",
      "Lung -->  [['hsa-mir-151a' nan 'Carcinoma, Lung, Non-Small-Cell' nan]\n",
      " ['hsa-mir-151a' nan 'Adenocarcinoma, Lung' nan]\n",
      " ['hsa-mir-151a' nan 'Carcinoma, Non-Small-Cell Lung' nan]] \n",
      "\n",
      "Diseases -->  [['hsa-mir-151a' nan 'Cardiovascular Diseases [unspecific]' nan]] \n",
      "\n",
      "-------------------------31-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-212  ||  disease_of_miRNA = Long QT Syndrome\n",
      "Long -->  [] \n",
      "\n",
      "QT -->  [] \n",
      "\n",
      "Syndrome -->  [['hsa-mir-212' nan 'Lofgren Syndrome' nan]] \n",
      "\n",
      "-------------------------32-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-661  ||  disease_of_miRNA = Leukemia, Promyelocytic, Acute\n",
      "Leukemia, -->  [] \n",
      "\n",
      "Promyelocytic, -->  [] \n",
      "\n",
      "Acute -->  [] \n",
      "\n",
      "-------------------------33-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-374a  ||  disease_of_miRNA = Leukemia, Myeloid, Chronic-Phase\n",
      "Leukemia, -->  [] \n",
      "\n",
      "Myeloid, --> "
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      " 57%|█████▋    | 44/77 [00:00<00:00, 48.98it/s]"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      " [] \n",
      "\n",
      "Chronic-Phase -->  [] \n",
      "\n",
      "-------------------------34-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-522  ||  disease_of_miRNA = Leukemia, Myelogenous, Chronic, BCR-ABL Positive\n",
      "Leukemia, -->  [] \n",
      "\n",
      "Myelogenous, -->  [] \n",
      "\n",
      "Chronic, -->  [] \n",
      "\n",
      "BCR-ABL -->  [] \n",
      "\n",
      "Positive -->  [] \n",
      "\n",
      "-------------------------35-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-2861  ||  disease_of_miRNA = Leukemia, B-Cell\n",
      "Leukemia, -->  [] \n",
      "\n",
      "B-Cell -->  [] \n",
      "\n",
      "-------------------------36-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-641  ||  disease_of_miRNA = Leiomyosarcoma\n",
      "Leiomyosarcoma -->  [] \n",
      "\n",
      "-------------------------37-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-571  ||  disease_of_miRNA = Laryngeal Neoplasms\n",
      "Laryngeal -->  [] \n",
      "\n",
      "Neoplasms -->  [] \n",
      "\n",
      "-------------------------38-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-655  ||  disease_of_miRNA = Kidney Neoplasms\n",
      "Kidney -->  [] \n",
      "\n",
      "Neoplasms -->  [['hsa-mir-655' nan 'Pituitary Neoplasms' nan]] \n",
      "\n",
      "-------------------------39-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-516a  ||  disease_of_miRNA = Ischemic Preconditioning\n",
      "Ischemic -->  [] \n",
      "\n",
      "Preconditioning -->  [] \n",
      "\n",
      "-------------------------40-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-942  ||  disease_of_miRNA = Ischemia\n",
      "Ischemia -->  [] \n",
      "\n",
      "-------------------------41-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-181  ||  disease_of_miRNA = Inflammation\n",
      "Inflammation -->  [['hsa-mir-181' nan 'Wound Inflammation' nan]\n",
      " ['hsa-mir-181' nan 'Inflammation' nan]] \n",
      "\n",
      "-------------------------42-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-212  ||  disease_of_miRNA = HIV\n",
      "HIV -->  [] \n",
      "\n",
      "-------------------------43-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-7  ||  disease_of_miRNA = Hepatitis C, Chronic\n",
      "Hepatitis -->  [] \n",
      "\n",
      "C, -->  [] \n",
      "\n",
      "Chronic -->  [['hsa-mir-7' nan 'Leukemia, Myeloid, Chronic' nan]] \n",
      "\n",
      "-------------------------44-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-1245a  ||  disease_of_miRNA = Hepatitis\n",
      "Hepatitis -->  [] \n",
      "\n",
      "-------------------------45-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-448  ||  disease_of_miRNA = Helplessness, Learned\n",
      "Helplessness, -->  [] \n",
      "\n",
      "Learned -->  [] \n",
      "\n",
      "-------------------------46-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-545  ||  disease_of_miRNA = HBV Infection\n",
      "HBV "
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      " 79%|███████▉  | 61/77 [00:01<00:00, 52.93it/s]"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "-->  [] \n",
      "\n",
      "Infection -->  [] \n",
      "\n",
      "-------------------------47-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-622  ||  disease_of_miRNA = Graves Disease\n",
      "Graves -->  [] \n",
      "\n",
      "Disease -->  [] \n",
      "\n",
      "-------------------------48-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-758  ||  disease_of_miRNA = Graft vs Host Disease\n",
      "Graft -->  [] \n",
      "\n",
      "vs -->  [] \n",
      "\n",
      "Host -->  [] \n",
      "\n",
      "Disease -->  [['hsa-mir-758' nan 'Cardiovascular Diseases [unspecific]' nan]] \n",
      "\n",
      "-------------------------49-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-320a  ||  disease_of_miRNA = Glomerulonephritis, IGA\n",
      "Glomerulonephritis, -->  [] \n",
      "\n",
      "IGA -->  [] \n",
      "\n",
      "-------------------------50-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-598  ||  disease_of_miRNA = Glomerulonephritis\n",
      "Glomerulonephritis -->  [] \n",
      "\n",
      "-------------------------51-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-648  ||  disease_of_miRNA = Frontotemporal Lobar Degeneration\n",
      "Frontotemporal -->  [] \n",
      "\n",
      "Lobar -->  [] \n",
      "\n",
      "Degeneration -->  [] \n",
      "\n",
      "-------------------------52-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-659  ||  disease_of_miRNA = Focal Epithelial Hyperplasia\n",
      "Focal -->  [] \n",
      "\n",
      "Epithelial -->  [] \n",
      "\n",
      "Hyperplasia -->  [] \n",
      "\n",
      "-------------------------53-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-205  ||  disease_of_miRNA = Fatty Liver, Alcoholic\n",
      "Fatty -->  [] \n",
      "\n",
      "Liver, -->  [] \n",
      "\n",
      "Alcoholic -->  [] \n",
      "\n",
      "-------------------------54-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-33a  ||  disease_of_miRNA = Endometrial Neoplasms\n",
      "Endometrial -->  [] \n",
      "\n",
      "Neoplasms -->  [['hsa-mir-33a' nan 'Lung Neoplasms' nan]\n",
      " ['hsa-mir-33a' nan 'Breast Neoplasms' nan]\n",
      " ['hsa-mir-33a' nan 'Laryngeal Neoplasms' nan]\n",
      " ['hsa-mir-33a' nan 'Colon Neoplasms' nan]\n",
      " ['hsa-mir-33a' nan 'Colorectal Neoplasms' nan]] \n",
      "\n",
      "-------------------------55-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-30c  ||  disease_of_miRNA = Encephalomyelitis, Autoimmune, Experimental\n",
      "Encephalomyelitis, -->  [] \n",
      "\n",
      "Autoimmune, -->  [] \n",
      "\n",
      "Experimental -->  [] \n",
      "\n",
      "-------------------------56-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-873  ||  disease_of_miRNA = Diabetic Retinopathy\n",
      "Diabetic -->  [] \n",
      "\n",
      "Retinopathy -->  [] \n",
      "\n",
      "-------------------------57-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-15b  ||  disease_of_miRNA = Diabetic Nephropathies\n",
      "Diabetic -->  [['hsa-mir-15b' nan 'Diabetic Nephropathy' nan]] \n",
      "\n",
      "Nephropathies -->  [] \n",
      "\n",
      "-------------------------58-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-512  ||  disease_of_miRNA = Diabetes Mellitus, Type 1\n",
      "Diabetes -->  [] \n",
      "\n",
      "Mellitus, -->  [] \n",
      "\n",
      "Type -->  [] \n",
      "\n",
      "1 -->  [] \n",
      "\n",
      "-------------------------59-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-378f  ||  disease_of_miRNA = Diabetes Complications\n",
      "Diabetes -->  [] \n",
      "\n",
      "Complications -->  [] \n",
      "\n",
      "-------------------------60-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-198  ||  disease_of_miRNA = Cystic Fibrosis\n",
      "Cystic -->  [] \n",
      "\n",
      "Fibrosis -->  [] \n",
      "\n",
      "-------------------------61-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-494  ||  disease_of_miRNA = Colitis, Ulcerative\n",
      "Colitis, -->  [] \n",
      "\n",
      "Ulcerative -->  [] \n",
      "\n",
      "-------------------------62-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-143  ||  disease_of_miRNA = Colitis\n",
      "Colitis -->  [['hsa-mir-143' nan 'Colitis, Ulcerative' nan]] \n",
      "\n",
      "-------------------------63-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-100  ||  disease_of_miRNA = Cocaine-Related Disorders\n",
      "Cocaine-Related -->  [] \n",
      "\n",
      "Disorders -->  [['hsa-mir-100' nan 'Muscular Disorders, Atrophic' nan]] \n",
      "\n",
      "-------------------------64-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-424  ||  disease_of_miRNA = Chondrodysplasia Punctata\n",
      "Chondrodysplasia -->  [] \n",
      "\n",
      "Punctata -->  [] \n",
      "\n",
      "-------------------------65-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-337  ||  disease_of_miRNA = Cervical Neoplasms\n",
      "Cervical -->  [['hsa-mir-337' nan 'Carcinoma, Cervical' nan]] \n",
      "\n",
      "Neoplasms -->  [['hsa-mir-337' nan 'Gastric Neoplasms' nan]\n",
      " ['hsa-mir-337' nan 'Salivary Gland Neoplasms' nan]\n",
      " ['hsa-mir-337' nan 'Colorectal Neoplasms' nan]] \n",
      "\n",
      "-------------------------66-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-370  ||  disease_of_miRNA = Carcinoma, Renal Cell\n"
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "\r",
      " 88%|████████▊ | 68/77 [00:01<00:00, 36.01it/s]"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Carcinoma, -->  [['hsa-mir-370' nan 'Carcinoma, Gastric' nan]\n",
      " ['hsa-mir-370' nan 'Carcinoma, Oral' nan]\n",
      " ['hsa-mir-370' nan 'Carcinoma, Lung, Non-Small-Cell' nan]\n",
      " ['hsa-mir-370' nan 'Carcinoma, Hepatocellular' nan]\n",
      " ['hsa-mir-370' nan 'Carcinoma, Lung' nan]\n",
      " ['hsa-mir-370' nan 'Squamous Cell Carcinoma, Esophageal' nan]\n",
      " ['hsa-mir-370' nan\n",
      "  'Squamous Cell Carcinoma, Laryngeal or Hypopharyngeal' nan]] \n",
      "\n",
      "Renal -->  [] \n",
      "\n",
      "Cell -->  [['hsa-mir-370' nan 'Carcinoma, Lung, Non-Small-Cell' nan]\n",
      " ['hsa-mir-370' nan 'Squamous Cell Carcinoma, Esophageal' nan]\n",
      " ['hsa-mir-370' nan\n",
      "  'Squamous Cell Carcinoma, Laryngeal or Hypopharyngeal' nan]] \n",
      "\n",
      "-------------------------67-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-603  ||  disease_of_miRNA = Carcinoma, Renal Cell\n",
      "Carcinoma, -->  [['hsa-mir-603' nan 'Carcinoma, Breast, Triple Negative' nan]] \n",
      "\n",
      "Renal -->  [] \n",
      "\n",
      "Cell -->  [] \n",
      "\n",
      "-------------------------68-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-30b  ||  disease_of_miRNA = Carcinoma, Ehrlich Tumor\n",
      "Carcinoma, -->  [['hsa-mir-30b' nan 'Squamous Cell Carcinoma, Lung' nan]\n",
      " ['hsa-mir-30b' nan 'Carcinoma, Breast' nan]\n",
      " ['hsa-mir-30b' nan 'Carcinoma, Laryngeal' nan]\n",
      " ['hsa-mir-30b' nan 'Carcinoma, Hepatocellular' nan]\n",
      " ['hsa-mir-30b' nan 'Carcinoma, Lung, Non-Small-Cell' nan]\n",
      " ['hsa-mir-30b' nan 'Carcinoma, Renal Cell' nan]\n",
      " ['hsa-mir-30b' nan 'Carcinoma, Cervical' nan]\n",
      " ['hsa-mir-30b' nan 'Carcinoma, Esophageal' nan]\n",
      " ['hsa-mir-30b' nan 'Squamous Cell Carcinoma, Oral' nan]] \n",
      "\n",
      "Ehrlich -->  [] \n",
      "\n",
      "Tumor -->  [] \n",
      "\n",
      "-------------------------69-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-154  ||  disease_of_miRNA = Burns\n",
      "Burns -->  [] \n",
      "\n",
      "-------------------------70-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-527  ||  disease_of_miRNA = Arthritis\n",
      "Arthritis -->  [] \n",
      "\n",
      "-------------------------71-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-610  ||  disease_of_miRNA = Angina, Unstable\n",
      "Angina, -->  [] \n",
      "\n",
      "Unstable -->  [] \n",
      "\n",
      "-------------------------72-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-410  ||  disease_of_miRNA = Alzheimer Disease\n",
      "Alzheimer -->  [] \n",
      "\n",
      "Disease -->  [['hsa-mir-410' nan 'Pelvic Inflammatory Disease' nan]] \n",
      "\n",
      "-------------------------73-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-147b  ||  disease_of_miRNA = Adenoma\n"
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "100%|██████████| 77/77 [00:01<00:00, 50.01it/s]"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Adenoma -->  [] \n",
      "\n",
      "-------------------------74-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-451b  ||  disease_of_miRNA = Acute Lung Injury\n",
      "Acute -->  [] \n",
      "\n",
      "Lung -->  [['hsa-mir-451b' nan 'Carcinoma, Lung, Non-Small-Cell' nan]\n",
      " ['hsa-mir-451b' nan 'Carcinoma, Non-Small-Cell Lung' nan]] \n",
      "\n",
      "Injury -->  [] \n",
      "\n",
      "-------------------------75-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-501  ||  disease_of_miRNA = Acquired Immunodeficiency Syndrome\n",
      "Acquired -->  [] \n",
      "\n",
      "Immunodeficiency -->  [] \n",
      "\n",
      "Syndrome -->  [] \n",
      "\n",
      "-------------------------76-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-1273a  ||  disease_of_miRNA = Abortion, Habitual\n",
      "Abortion, -->  [] \n",
      "\n",
      "Habitual -->  [] \n",
      "\n"
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "\n"
     ]
    }
   ],
   "source": [
    "results_Tp, new_MDA_Tp, new_MDA_simplied_Tp, database_data_miRNA_in_results_Tp = run(task = 'Tp', database_data = database_data)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 10,
   "metadata": {},
   "outputs": [
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "/home/chujunyi/anaconda3/envs/python36/lib/python3.6/site-packages/ipykernel_launcher.py:2: UserWarning: Boolean Series key will be reindexed to match DataFrame index.\n",
      "  \n",
      "/home/chujunyi/anaconda3/envs/python36/lib/python3.6/site-packages/ipykernel_launcher.py:14: SettingWithCopyWarning: \n",
      "A value is trying to be set on a copy of a slice from a DataFrame.\n",
      "Try using .loc[row_indexer,col_indexer] = value instead\n",
      "\n",
      "See the caveats in the documentation: http://pandas.pydata.org/pandas-docs/stable/user_guide/indexing.html#returning-a-view-versus-a-copy\n",
      "  \n",
      "  4%|▍         | 2/51 [00:00<00:02, 18.52it/s]"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "-------------------------0-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-551a  ||  disease_of_miRNA = Waldenstrom Macroglobulinemia\n",
      "Waldenstrom -->  [] \n",
      "\n",
      "Macroglobulinemia -->  [] \n",
      "\n",
      "-------------------------1-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-611  ||  disease_of_miRNA = Waldenstrom Macroglobulinemia\n",
      "Waldenstrom -->  [] \n",
      "\n",
      "Macroglobulinemia -->  [] \n",
      "\n",
      "-------------------------2-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-324  ||  disease_of_miRNA = Vascular Calcification\n",
      "Vascular -->  [] \n",
      "\n",
      "Calcification -->  [] \n",
      "\n",
      "-------------------------3-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-371a  ||  disease_of_miRNA = Vascular Calcification\n",
      "Vascular -->  [] \n",
      "\n",
      "Calcification -->  [] \n",
      "\n",
      "-------------------------4-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-300  ||  disease_of_miRNA = Sepsis\n",
      "Sepsis -->  [] \n",
      "\n",
      "-------------------------5-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-10b  ||  disease_of_miRNA = Sepsis\n",
      "Sepsis -->  [] \n",
      "\n",
      "-------------------------6-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-146a  ||  disease_of_miRNA = Salivary Gland Neoplasms\n",
      "Salivary -->  [] \n",
      "\n",
      "Gland -->  [] \n",
      "\n",
      "Neoplasms -->  "
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      " 24%|██▎       | 12/51 [00:00<00:01, 25.51it/s]"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "[['hsa-mir-146a' nan 'Pancreatic Neoplasms' nan]\n",
      " ['hsa-mir-146a' nan 'Prostate Neoplasms' nan]\n",
      " ['hsa-mir-146a' nan 'Gastric Neoplasms' nan]\n",
      " ['hsa-mir-146a' nan 'Breast Neoplasms' nan]\n",
      " ['hsa-mir-146a' nan 'Thyroid Neoplasms' nan]\n",
      " ['hsa-mir-146a' nan 'Ovarian Neoplasms' nan]\n",
      " ['hsa-mir-146a' nan 'Gastrointestinal Neoplasms' nan]\n",
      " ['hsa-mir-146a' nan 'Esophageal Neoplasms' nan]\n",
      " ['hsa-mir-146a' nan 'Nasopharyngeal Neoplasms' nan]\n",
      " ['hsa-mir-146a' nan 'Lung Neoplasms' nan]\n",
      " ['hsa-mir-146a' nan 'Digestive System Neoplasms' nan]\n",
      " ['hsa-mir-146a' nan 'Neoplasms [unspecific]' nan]\n",
      " ['hsa-mir-146a' nan 'Skin Neoplasms' nan]\n",
      " ['hsa-mir-146a' nan 'Endometrial Neoplasms' nan]\n",
      " ['hsa-mir-146a' nan 'Head And Neck Neoplasms' nan]\n",
      " ['hsa-mir-146a' nan 'Bladder Neoplasms' nan]\n",
      " ['hsa-mir-146a' nan 'Cervical Neoplasms' nan]\n",
      " ['hsa-mir-146a' nan 'Colon Neoplasms' nan]\n",
      " ['hsa-mir-146a' nan 'Liver Neoplasms' nan]\n",
      " ['hsa-mir-146a' nan 'Prostatic Neoplasms' nan]\n",
      " ['hsa-mir-146a' nan 'Uterine Cervical Neoplasms' nan]\n",
      " ['hsa-mir-146a' nan 'Colonic Neoplasms' nan]\n",
      " ['hsa-mir-146a' nan 'Neoplasms' nan]\n",
      " ['hsa-mir-146a' nan 'Stomach Neoplasms' nan]\n",
      " ['hsa-mir-146a' nan 'Urinary Bladder Neoplasms' nan]\n",
      " ['hsa-mir-146a' nan 'Colorectal Neoplasms' nan]] \n",
      "\n",
      "-------------------------7-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-15a  ||  disease_of_miRNA = Salivary Gland Neoplasms\n",
      "Salivary -->  [['hsa-mir-15a' nan 'Salivary Gland Neoplasms' nan]] \n",
      "\n",
      "Gland -->  [['hsa-mir-15a' nan 'Salivary Gland Neoplasms' nan]] \n",
      "\n",
      "Neoplasms -->  [['hsa-mir-15a' nan 'Pituitary Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Prostate Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Kidney Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Breast Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Neoplasms [unspecific]' nan]\n",
      " ['hsa-mir-15a' nan 'Hematologic Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Gastric Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Colon Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Laryngeal Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Head And Neck Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Lung Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Myeloproliferative Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Pancreatic Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Salivary Gland Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Bladder Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Esophageal Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Prostatic Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Head and Neck Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Colonic Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Urinary Bladder Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Neoplasms' nan]] \n",
      "\n",
      "-------------------------8-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-589  ||  disease_of_miRNA = Salivary Gland Neoplasms\n",
      "Salivary -->  [] \n",
      "\n",
      "Gland -->  [] \n",
      "\n",
      "Neoplasms -->  [['hsa-mir-589' nan 'Gastric Neoplasms' nan]] \n",
      "\n",
      "-------------------------9-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-378c  ||  disease_of_miRNA = Renal Insufficiency\n",
      "Renal -->  [['hsa-mir-378c' nan 'Carcinoma, Renal Cell' nan]] \n",
      "\n",
      "Insufficiency -->  [] \n",
      "\n",
      "-------------------------10-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-518a  ||  disease_of_miRNA = Pulmonary Disease, Chronic Obstructive\n",
      "Pulmonary -->  [] \n",
      "\n",
      "Disease, -->  [] \n",
      "\n",
      "Chronic -->  [] \n",
      "\n",
      "Obstructive -->  [] \n",
      "\n",
      "-------------------------11-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-641  ||  disease_of_miRNA = Papilary thyroid carcinoma\n",
      "Papilary -->  [] \n",
      "\n",
      "thyroid -->  [] \n",
      "\n",
      "carcinoma -->  [] \n",
      "\n",
      "-------------------------12-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-561  ||  disease_of_miRNA = Osteoporosis\n",
      "Osteoporosis -->  [] \n",
      "\n",
      "-------------------------13-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-410  ||  disease_of_miRNA = Osteoporosis\n",
      "Osteoporosis -->  [] \n",
      "\n",
      "-------------------------14-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-1280  ||  disease_of_miRNA = Osteoarthritis\n",
      "Osteoarthritis -->  [] \n",
      "\n",
      "-------------------------15-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-647  ||  disease_of_miRNA = Osteoarthritis\n",
      "Osteoarthritis "
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      " 51%|█████     | 26/51 [00:00<00:00, 34.11it/s]"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "-->  [] \n",
      "\n",
      "-------------------------16-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-18a  ||  disease_of_miRNA = Neurofibromatosis 2\n",
      "Neurofibromatosis -->  [] \n",
      "\n",
      "2 -->  [['hsa-mir-18a' nan 'Diabetes Mellitus, Type 2' nan]] \n",
      "\n",
      "-------------------------17-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-431  ||  disease_of_miRNA = Myocytes, Cardiac\n",
      "Myocytes, -->  [] \n",
      "\n",
      "Cardiac -->  [] \n",
      "\n",
      "-------------------------18-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-181d  ||  disease_of_miRNA = Musculoskeletal Abnormalities\n",
      "Musculoskeletal -->  [] \n",
      "\n",
      "Abnormalities -->  [] \n",
      "\n",
      "-------------------------19-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-769  ||  disease_of_miRNA = Mastocytosis, Systemic\n",
      "Mastocytosis, -->  [] \n",
      "\n",
      "Systemic -->  [] \n",
      "\n",
      "-------------------------20-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-151a  ||  disease_of_miRNA = Lung Diseases\n",
      "Lung -->  [['hsa-mir-151a' nan 'Carcinoma, Lung, Non-Small-Cell' nan]\n",
      " ['hsa-mir-151a' nan 'Adenocarcinoma, Lung' nan]\n",
      " ['hsa-mir-151a' nan 'Carcinoma, Non-Small-Cell Lung' nan]] \n",
      "\n",
      "Diseases -->  [['hsa-mir-151a' nan 'Cardiovascular Diseases [unspecific]' nan]] \n",
      "\n",
      "-------------------------21-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-661  ||  disease_of_miRNA = Leukemia, Promyelocytic, Acute\n",
      "Leukemia, -->  [] \n",
      "\n",
      "Promyelocytic, -->  [] \n",
      "\n",
      "Acute -->  [] \n",
      "\n",
      "-------------------------22-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-2861  ||  disease_of_miRNA = Leukemia, B-Cell\n",
      "Leukemia, -->  [] \n",
      "\n",
      "B-Cell -->  [] \n",
      "\n",
      "-------------------------23-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-641  ||  disease_of_miRNA = Leiomyosarcoma\n",
      "Leiomyosarcoma -->  [] \n",
      "\n",
      "-------------------------24-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-655  ||  disease_of_miRNA = Kidney Neoplasms\n",
      "Kidney -->  [] \n",
      "\n",
      "Neoplasms -->  [['hsa-mir-655' nan 'Pituitary Neoplasms' nan]] \n",
      "\n",
      "-------------------------25-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-614  ||  disease_of_miRNA = Kidney Failure, Acute\n",
      "Kidney -->  [] \n",
      "\n",
      "Failure, -->  [] \n",
      "\n",
      "Acute -->  [] \n",
      "\n",
      "-------------------------26-th new MDA--------------------------------------------\n"
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "\r",
      " 61%|██████    | 31/51 [00:00<00:00, 34.83it/s]"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "miRNA = hsa-mir-516a  ||  disease_of_miRNA = Ischemic Preconditioning\n",
      "Ischemic -->  [] \n",
      "\n",
      "Preconditioning -->  [] \n",
      "\n",
      "-------------------------27-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-29a  ||  disease_of_miRNA = Huntington Disease\n",
      "Huntington -->  [] \n",
      "\n",
      "Disease -->  [['hsa-mir-29a' nan 'Parkinson Disease' nan]\n",
      " ['hsa-mir-29a' nan 'Alzheimer Disease' nan]\n",
      " ['hsa-mir-29a' nan 'Machado-Joseph Disease' nan]\n",
      " ['hsa-mir-29a' nan 'Liver Diseases [unspecific]' nan]\n",
      " ['hsa-mir-29a' nan 'Crohn Disease' nan]\n",
      " ['hsa-mir-29a' nan 'Kidney Diseases [unspecific]' nan]\n",
      " ['hsa-mir-29a' nan 'Vascular Disease [unspecific]' nan]\n",
      " ['hsa-mir-29a' nan 'Heart Valve Disease' nan]\n",
      " ['hsa-mir-29a' nan 'Mitochondrial Metabolism Disease' nan]\n",
      " ['hsa-mir-29a' nan 'Autoimmune Diseases [unspecific]' nan]\n",
      " ['hsa-mir-29a' nan 'Kidney Diseases' nan]\n",
      " ['hsa-mir-29a' nan 'Liver Diseases' nan]] \n",
      "\n",
      "-------------------------28-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-190a  ||  disease_of_miRNA = Hepatitis C\n",
      "Hepatitis -->  [] \n",
      "\n",
      "C -->  [['hsa-mir-190a' nan 'Carcinoma, Breast, Triple Negative' nan]\n",
      " ['hsa-mir-190a' nan 'Carcinoma, Hepatocellular' nan]\n",
      " ['hsa-mir-190a' nan 'Colorectal Carcinoma' nan]\n",
      " ['hsa-mir-190a' nan 'Colorectal Neoplasms' nan]] \n",
      "\n",
      "-------------------------29-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-1245a  ||  disease_of_miRNA = Hepatitis\n",
      "Hepatitis -->  [] \n",
      "\n",
      "-------------------------30-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-324  ||  disease_of_miRNA = Hemangiosarcoma\n",
      "Hemangiosarcoma -->  [] \n",
      "\n",
      "-------------------------31-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-532  ||  disease_of_miRNA = Hand, Foot and Mouth Disease\n",
      "Hand, -->  [] \n",
      "\n",
      "Foot -->  [] \n",
      "\n",
      "and -->  [] \n",
      "\n",
      "Mouth -->  [] \n",
      "\n",
      "Disease -->  [['hsa-mir-532' nan 'Alzheimer Disease' nan]\n",
      " ['hsa-mir-532' nan 'Crohn Disease' nan]] \n",
      "\n",
      "-------------------------32-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-622  ||  disease_of_miRNA = Graves Disease\n",
      "Graves -->  [] \n",
      "\n",
      "Disease -->  [] \n",
      "\n",
      "-------------------------33-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-758  ||  disease_of_miRNA = Graft vs Host Disease\n",
      "Graft -->  [] \n",
      "\n",
      "vs -->  [] \n",
      "\n",
      "Host -->  [] \n",
      "\n",
      "Disease -->  [['hsa-mir-758' nan 'Cardiovascular Diseases [unspecific]' nan]] \n",
      "\n",
      "-------------------------34-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-320a  ||  disease_of_miRNA = Glomerulonephritis, IGA\n",
      "Glomerulonephritis, -->  [] \n",
      "\n",
      "IGA -->  [] \n",
      "\n",
      "-------------------------35-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-941  ||  disease_of_miRNA = Fibrosis\n"
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "100%|██████████| 51/51 [00:00<00:00, 52.70it/s]"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Fibrosis -->  [] \n",
      "\n",
      "-------------------------36-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-423  ||  disease_of_miRNA = Endometriosis\n",
      "Endometriosis -->  [] \n",
      "\n",
      "-------------------------37-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-15b  ||  disease_of_miRNA = Diabetic Nephropathies\n",
      "Diabetic -->  [['hsa-mir-15b' nan 'Diabetic Nephropathy' nan]] \n",
      "\n",
      "Nephropathies -->  [] \n",
      "\n",
      "-------------------------38-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-378f  ||  disease_of_miRNA = Diabetes Complications\n",
      "Diabetes -->  [] \n",
      "\n",
      "Complications -->  [] \n",
      "\n",
      "-------------------------39-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-198  ||  disease_of_miRNA = Cystic Fibrosis\n",
      "Cystic -->  [] \n",
      "\n",
      "Fibrosis -->  [] \n",
      "\n",
      "-------------------------40-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-1184  ||  disease_of_miRNA = Colorectal Neoplasms, Hereditary Nonpolyposis\n",
      "Colorectal -->  [] \n",
      "\n",
      "Neoplasms, -->  [] \n",
      "\n",
      "Hereditary -->  [] \n",
      "\n",
      "Nonpolyposis -->  [] \n",
      "\n",
      "-------------------------41-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-494  ||  disease_of_miRNA = Colitis, Ulcerative\n",
      "Colitis, -->  [] \n",
      "\n",
      "Ulcerative -->  [] \n",
      "\n",
      "-------------------------42-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-424  ||  disease_of_miRNA = Chondrodysplasia Punctata\n",
      "Chondrodysplasia -->  [] \n",
      "\n",
      "Punctata -->  [] \n",
      "\n",
      "-------------------------43-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-655  ||  disease_of_miRNA = Carcinoma, Squamous Cell\n",
      "Carcinoma, -->  [['hsa-mir-655' nan 'Carcinoma, Renal Cell' nan]\n",
      " ['hsa-mir-655' nan 'Squamous Cell Carcinoma, Oral' nan]\n",
      " ['hsa-mir-655' nan 'Carcinoma, Hepatocellular' nan]\n",
      " ['hsa-mir-655' nan 'Squamous Cell Carcinoma, Esophageal' nan]] \n",
      "\n",
      "Squamous -->  [['hsa-mir-655' nan 'Squamous Cell Carcinoma, Oral' nan]\n",
      " ['hsa-mir-655' nan 'Squamous Cell Carcinoma, Esophageal' nan]] \n",
      "\n",
      "Cell -->  [['hsa-mir-655' nan 'Carcinoma, Renal Cell' nan]\n",
      " ['hsa-mir-655' nan 'Squamous Cell Carcinoma, Oral' nan]\n",
      " ['hsa-mir-655' nan 'Squamous Cell Carcinoma, Esophageal' nan]] \n",
      "\n",
      "-------------------------44-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-365b  ||  disease_of_miRNA = Carcinoma, Ductal, Breast\n",
      "Carcinoma, -->  [['hsa-mir-365b' nan 'Carcinoma, Renal Cell' nan]\n",
      " ['hsa-mir-365b' nan 'Carcinoma, Hepatocellular' nan]] \n",
      "\n",
      "Ductal, -->  [] \n",
      "\n",
      "Breast -->  [['hsa-mir-365b' nan 'Breast Neoplasms' nan]] \n",
      "\n",
      "-------------------------45-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-154  ||  disease_of_miRNA = Burns\n",
      "Burns -->  [] \n",
      "\n",
      "-------------------------46-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-30d  ||  disease_of_miRNA = Atrophy\n",
      "Atrophy -->  [] \n",
      "\n",
      "-------------------------47-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-30e  ||  disease_of_miRNA = Aortic Aneurysm, Abdominal\n",
      "Aortic -->  [['hsa-mir-30e' nan 'Aortic Aneurysm, Thoracic' nan]] \n",
      "\n",
      "Aneurysm, -->  [['hsa-mir-30e' nan 'Aortic Aneurysm, Thoracic' nan]] \n",
      "\n",
      "Abdominal -->  [] \n",
      "\n",
      "-------------------------48-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-410  ||  disease_of_miRNA = Alzheimer Disease\n",
      "Alzheimer -->  [] \n",
      "\n",
      "Disease -->  [['hsa-mir-410' nan 'Pelvic Inflammatory Disease' nan]] \n",
      "\n",
      "-------------------------49-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-630  ||  disease_of_miRNA = Alopecia\n",
      "Alopecia -->  [] \n",
      "\n",
      "-------------------------50-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-451b  ||  disease_of_miRNA = Acute Lung Injury\n",
      "Acute -->  [] \n",
      "\n",
      "Lung -->  [['hsa-mir-451b' nan 'Carcinoma, Lung, Non-Small-Cell' nan]\n",
      " ['hsa-mir-451b' nan 'Carcinoma, Non-Small-Cell Lung' nan]] \n",
      "\n",
      "Injury -->  [] \n",
      "\n"
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "\n"
     ]
    }
   ],
   "source": [
    "results_Tm, new_MDA_Tm, new_MDA_simplied_Tm, database_data_miRNA_in_results_Tm = run(task = 'Tm', database_data = database_data)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 11,
   "metadata": {},
   "outputs": [
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "/home/chujunyi/anaconda3/envs/python36/lib/python3.6/site-packages/ipykernel_launcher.py:2: UserWarning: Boolean Series key will be reindexed to match DataFrame index.\n",
      "  \n",
      "/home/chujunyi/anaconda3/envs/python36/lib/python3.6/site-packages/ipykernel_launcher.py:14: SettingWithCopyWarning: \n",
      "A value is trying to be set on a copy of a slice from a DataFrame.\n",
      "Try using .loc[row_indexer,col_indexer] = value instead\n",
      "\n",
      "See the caveats in the documentation: http://pandas.pydata.org/pandas-docs/stable/user_guide/indexing.html#returning-a-view-versus-a-copy\n",
      "  \n",
      "  4%|▍         | 3/68 [00:00<00:02, 27.30it/s]"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "-------------------------0-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-324  ||  disease_of_miRNA = Vascular Calcification\n",
      "Vascular -->  [] \n",
      "\n",
      "Calcification -->  [] \n",
      "\n",
      "-------------------------1-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-582  ||  disease_of_miRNA = Thyroid Neoplasms\n",
      "Thyroid -->  [] \n",
      "\n",
      "Neoplasms -->  [['hsa-mir-582' nan 'Lung Neoplasms' nan]\n",
      " ['hsa-mir-582' nan 'Prostate Neoplasms' nan]] \n",
      "\n",
      "-------------------------2-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-342  ||  disease_of_miRNA = Stroke\n",
      "Stroke -->  [] \n",
      "\n",
      "-------------------------3-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-640  ||  disease_of_miRNA = Skin Neoplasms\n",
      "Skin -->  [] \n",
      "\n",
      "Neoplasms -->  [['hsa-mir-640' nan 'Gastric Neoplasms' nan]\n",
      " ['hsa-mir-640' nan 'Stomach Neoplasms' nan]] \n",
      "\n",
      "-------------------------4-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-98  ||  disease_of_miRNA = Scleroderma, Systemic\n",
      "Scleroderma, -->  [] \n",
      "\n",
      "Systemic -->  [['hsa-mir-98' nan 'Systemic Lupus Erythematosus' nan]] \n",
      "\n",
      "-------------------------5-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-1256  ||  disease_of_miRNA = Scleroderma, Localized\n",
      "Scleroderma, -->  [] \n",
      "\n",
      "Localized -->  [] \n",
      "\n",
      "-------------------------6-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-494  ||  disease_of_miRNA = Scleroderma, Localized\n",
      "Scleroderma, -->  [] \n",
      "\n",
      "Localized -->  [] \n",
      "\n",
      "-------------------------7-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-15a  ||  disease_of_miRNA = Salivary Gland Neoplasms\n"
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      " 19%|█▉        | 13/68 [00:00<00:01, 31.11it/s]"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Salivary -->  [['hsa-mir-15a' nan 'Salivary Gland Neoplasms' nan]] \n",
      "\n",
      "Gland -->  [['hsa-mir-15a' nan 'Salivary Gland Neoplasms' nan]] \n",
      "\n",
      "Neoplasms -->  [['hsa-mir-15a' nan 'Pituitary Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Prostate Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Kidney Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Breast Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Neoplasms [unspecific]' nan]\n",
      " ['hsa-mir-15a' nan 'Hematologic Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Gastric Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Colon Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Laryngeal Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Head And Neck Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Lung Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Myeloproliferative Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Pancreatic Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Salivary Gland Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Bladder Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Esophageal Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Prostatic Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Head and Neck Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Colonic Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Urinary Bladder Neoplasms' nan]\n",
      " ['hsa-mir-15a' nan 'Neoplasms' nan]] \n",
      "\n",
      "-------------------------8-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-374a  ||  disease_of_miRNA = Rhinitis, Allergic, Perennial\n",
      "Rhinitis, -->  [] \n",
      "\n",
      "Allergic, -->  [] \n",
      "\n",
      "Perennial -->  [] \n",
      "\n",
      "-------------------------9-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-589  ||  disease_of_miRNA = Radiation Injuries\n",
      "Radiation -->  [] \n",
      "\n",
      "Injuries -->  [] \n",
      "\n",
      "-------------------------10-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-526a  ||  disease_of_miRNA = Precursor B-Cell Lymphoblastic Leukemia-Lymphoma\n",
      "Precursor -->  [] \n",
      "\n",
      "B-Cell -->  [] \n",
      "\n",
      "Lymphoblastic -->  [] \n",
      "\n",
      "Leukemia-Lymphoma -->  [] \n",
      "\n",
      "-------------------------11-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-641  ||  disease_of_miRNA = Papilary thyroid carcinoma\n",
      "Papilary -->  [] \n",
      "\n",
      "thyroid -->  [] \n",
      "\n",
      "carcinoma -->  [] \n",
      "\n",
      "-------------------------12-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-561  ||  disease_of_miRNA = Osteoporosis\n",
      "Osteoporosis -->  [] \n",
      "\n",
      "-------------------------13-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-922  ||  disease_of_miRNA = Nevus, Pigmented\n",
      "Nevus, -->  [] \n",
      "\n"
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      " 29%|██▉       | 20/68 [00:00<00:01, 31.47it/s]"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Pigmented -->  [] \n",
      "\n",
      "-------------------------14-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-4257  ||  disease_of_miRNA = Nervous System Diseases\n",
      "Nervous -->  [] \n",
      "\n",
      "System -->  [] \n",
      "\n",
      "Diseases -->  [] \n",
      "\n",
      "-------------------------15-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-449b  ||  disease_of_miRNA = Myocytes, Cardiac\n",
      "Myocytes, -->  [] \n",
      "\n",
      "Cardiac -->  [] \n",
      "\n",
      "-------------------------16-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-181d  ||  disease_of_miRNA = Musculoskeletal Abnormalities\n",
      "Musculoskeletal -->  [] \n",
      "\n",
      "Abnormalities -->  [] \n",
      "\n",
      "-------------------------17-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-938  ||  disease_of_miRNA = Muscular Dystrophy, Facioscapulohumeral\n",
      "Muscular -->  [] \n",
      "\n",
      "Dystrophy, -->  [] \n",
      "\n",
      "Facioscapulohumeral -->  [] \n",
      "\n",
      "-------------------------18-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-449b  ||  disease_of_miRNA = Mouth Neoplasms\n",
      "Mouth -->  [] \n",
      "\n",
      "Neoplasms -->  [['hsa-mir-449b' nan 'Prostate Neoplasms' nan]\n",
      " ['hsa-mir-449b' nan 'Neoplasms [unspecific]' nan]\n",
      " ['hsa-mir-449b' nan 'Liver Neoplasms' nan]\n",
      " ['hsa-mir-449b' nan 'Gastric Neoplasms' nan]\n",
      " ['hsa-mir-449b' nan 'Salivary Gland Neoplasms' nan]\n",
      " ['hsa-mir-449b' nan 'Ovarian Neoplasms' nan]\n",
      " ['hsa-mir-449b' nan 'Bladder Neoplasms' nan]\n",
      " ['hsa-mir-449b' nan 'Stomach Neoplasms' nan]] \n",
      "\n",
      "-------------------------19-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-545  ||  disease_of_miRNA = Mouth Neoplasms\n",
      "Mouth -->  [['hsa-mir-545' nan 'Hand, Foot And Mouth Disease' nan]\n",
      " ['hsa-mir-545' nan 'Hand, Foot and Mouth Disease' nan]] \n",
      "\n",
      "Neoplasms -->  [['hsa-mir-545' nan 'Neoplasms [unspecific]' nan]\n",
      " ['hsa-mir-545' nan 'Ovarian Neoplasms' nan]\n",
      " ['hsa-mir-545' nan 'Lung Neoplasms' nan]\n",
      " ['hsa-mir-545' nan 'Gastric Neoplasms' nan]\n",
      " ['hsa-mir-545' nan 'Colon Neoplasms' nan]] \n",
      "\n",
      "-------------------------20-th new MDA--------------------------------------------\n"
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "\r",
      " 34%|███▍      | 23/68 [00:00<00:01, 26.29it/s]"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "miRNA = hsa-mir-769  ||  disease_of_miRNA = Mastocytosis, Systemic\n",
      "Mastocytosis, -->  [] \n",
      "\n",
      "Systemic -->  [] \n",
      "\n",
      "-------------------------21-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-654  ||  disease_of_miRNA = Lymphoma, Large-Cell, Anaplastic\n",
      "Lymphoma, -->  [] \n",
      "\n",
      "Large-Cell, -->  [] \n",
      "\n",
      "Anaplastic -->  [] \n",
      "\n",
      "-------------------------22-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-1293  ||  disease_of_miRNA = Lymphoma\n",
      "Lymphoma -->  [] \n",
      "\n",
      "-------------------------23-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-151a  ||  disease_of_miRNA = Lung Diseases\n",
      "Lung -->  [['hsa-mir-151a' nan 'Carcinoma, Lung, Non-Small-Cell' nan]\n",
      " ['hsa-mir-151a' nan 'Adenocarcinoma, Lung' nan]\n",
      " ['hsa-mir-151a' nan 'Carcinoma, Non-Small-Cell Lung' nan]] \n",
      "\n",
      "Diseases -->  [['hsa-mir-151a' nan 'Cardiovascular Diseases [unspecific]' nan]] \n",
      "\n",
      "-------------------------24-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-19a  ||  disease_of_miRNA = Liver Diseases, Alcoholic\n",
      "Liver -->  [] \n",
      "\n",
      "Diseases, -->  [['hsa-mir-19a' nan 'Lung Diseases, Interstitial' nan]] \n",
      "\n",
      "Alcoholic -->  [] \n",
      "\n",
      "-------------------------25-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-661  ||  disease_of_miRNA = Leukemia, Promyelocytic, Acute\n",
      "Leukemia, -->  [] \n",
      "\n",
      "Promyelocytic, -->  [] \n",
      "\n",
      "Acute -->  [] \n",
      "\n",
      "-------------------------26-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-150  ||  disease_of_miRNA = Leukemia, Promyelocytic, Acute\n",
      "Leukemia, -->  [['hsa-mir-150' nan 'Leukemia, Lymphocytic, Chronic, B-Cell' nan]\n",
      " ['hsa-mir-150' nan 'Leukemia, Myeloid, Chronic' nan]\n",
      " ['hsa-mir-150' nan 'Leukemia, Myeloid, Acute' nan]\n",
      " ['hsa-mir-150' nan 'Leukemia, Lymphoblastic, Acute' nan]\n",
      " ['hsa-mir-150' nan 'Leukemia, Acute' nan]\n",
      " ['hsa-mir-150' nan 'Leukemia, Myeloid' nan]] \n",
      "\n",
      "Promyelocytic, -->  [] \n",
      "\n"
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      " 49%|████▊     | 33/68 [00:00<00:01, 33.17it/s]"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Acute -->  [['hsa-mir-150' nan 'Leukemia, Myeloid, Acute' nan]\n",
      " ['hsa-mir-150' nan 'Leukemia, Lymphoblastic, Acute' nan]\n",
      " ['hsa-mir-150' nan 'Leukemia, Acute' nan]\n",
      " ['hsa-mir-150' nan 'Acute Myocardial Infarction' nan]] \n",
      "\n",
      "-------------------------27-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-641  ||  disease_of_miRNA = Leiomyosarcoma\n",
      "Leiomyosarcoma -->  [] \n",
      "\n",
      "-------------------------28-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-1280  ||  disease_of_miRNA = Leiomyosarcoma\n",
      "Leiomyosarcoma -->  [] \n",
      "\n",
      "-------------------------29-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-655  ||  disease_of_miRNA = Kidney Neoplasms\n",
      "Kidney -->  [] \n",
      "\n",
      "Neoplasms -->  [['hsa-mir-655' nan 'Pituitary Neoplasms' nan]] \n",
      "\n",
      "-------------------------30-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-520f  ||  disease_of_miRNA = Ischemia\n",
      "Ischemia -->  [] \n",
      "\n",
      "-------------------------31-th new MDA--------------------------------------------\n",
      "miRNA = hsa-let-7g  ||  disease_of_miRNA = HEV\n",
      "HEV -->  [] \n",
      "\n",
      "-------------------------32-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-190a  ||  disease_of_miRNA = Hepatitis C\n",
      "Hepatitis -->  [] \n",
      "\n",
      "C -->  [['hsa-mir-190a' nan 'Carcinoma, Breast, Triple Negative' nan]\n",
      " ['hsa-mir-190a' nan 'Carcinoma, Hepatocellular' nan]\n",
      " ['hsa-mir-190a' nan 'Colorectal Carcinoma' nan]\n",
      " ['hsa-mir-190a' nan 'Colorectal Neoplasms' nan]] \n",
      "\n",
      "-------------------------33-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-497  ||  disease_of_miRNA = Hepatitis C\n",
      "Hepatitis -->  [] \n",
      "\n",
      "C -->  [['hsa-mir-497' nan 'Carcinoma, Cervical' nan]\n",
      " ['hsa-mir-497' nan 'Carcinoma, Hepatocellular' nan]\n",
      " ['hsa-mir-497' nan 'Invasive Bladder Transitional Cell Carcinoma' nan]\n",
      " ['hsa-mir-497' nan 'Carcinoma, Ovarian' nan]\n",
      " ['hsa-mir-497' nan 'Squamous Cell Carcinoma, Cerevial' nan]\n",
      " ['hsa-mir-497' nan 'Colorectal Carcinoma' nan]\n",
      " ['hsa-mir-497' nan 'Leukemia, Lymphocytic, Chronic, B-Cell' nan]\n",
      " ['hsa-mir-497' nan 'Carcinoma, Lung, Non-Small-Cell' nan]\n",
      " ['hsa-mir-497' nan 'Cerebral Ischemia' nan]\n",
      " ['hsa-mir-497' nan 'Carcinoma, Renal Cell, Clear-Cell' nan]\n",
      " ['hsa-mir-497' nan 'Urinary Bladder Cancer' nan]\n",
      " ['hsa-mir-497' nan 'Carcinoma, Adrenocortical' nan]\n",
      " ['hsa-mir-497' nan 'Cardiomyopathy, Hypertrophic' nan]\n",
      " ['hsa-mir-497' nan 'Squamous Cell Carcinoma' nan]\n",
      " ['hsa-mir-497' nan 'Carcinoma, Squamous Cell' nan]\n",
      " ['hsa-mir-497' nan 'Colorectal Neoplasms' nan]\n",
      " ['hsa-mir-497' nan 'Uterine Cervical Neoplasms' nan]\n",
      " ['hsa-mir-497' nan 'Carcinoma, Non-Small-Cell Lung' nan]] \n",
      "\n",
      "-------------------------34-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-1245a  ||  disease_of_miRNA = Hepatitis\n",
      "Hepatitis -->  [] \n",
      "\n",
      "-------------------------35-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-324  ||  disease_of_miRNA = Hemangiosarcoma\n",
      "Hemangiosarcoma"
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "\r",
      " 66%|██████▌   | 45/68 [00:01<00:00, 38.52it/s]"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      " -->  [] \n",
      "\n",
      "-------------------------36-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-448  ||  disease_of_miRNA = Helplessness, Learned\n",
      "Helplessness, -->  [] \n",
      "\n",
      "Learned -->  [] \n",
      "\n",
      "-------------------------37-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-147a  ||  disease_of_miRNA = Hearing Loss\n",
      "Hearing -->  [] \n",
      "\n",
      "Loss -->  [] \n",
      "\n",
      "-------------------------38-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-611  ||  disease_of_miRNA = HCMV Infection\n",
      "HCMV -->  [] \n",
      "\n",
      "Infection -->  [] \n",
      "\n",
      "-------------------------39-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-758  ||  disease_of_miRNA = Graft vs Host Disease\n",
      "Graft -->  [] \n",
      "\n",
      "vs -->  [] \n",
      "\n",
      "Host -->  [] \n",
      "\n",
      "Disease -->  [['hsa-mir-758' nan 'Cardiovascular Diseases [unspecific]' nan]] \n",
      "\n",
      "-------------------------40-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-200c  ||  disease_of_miRNA = Gout\n",
      "Gout -->  [] \n",
      "\n",
      "-------------------------41-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-1285  ||  disease_of_miRNA = Giant Cell Tumors\n",
      "Giant -->  [] \n",
      "\n",
      "Cell -->  [['hsa-mir-1285' nan 'Carcinoma, Lung, Non-Small-Cell' nan]] \n",
      "\n",
      "Tumors -->  [] \n",
      "\n",
      "-------------------------42-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-346  ||  disease_of_miRNA = Gastric Neoplasms\n",
      "Gastric -->  [] \n",
      "\n",
      "Neoplasms -->  [['hsa-mir-346' nan 'Lung Neoplasms' nan]] \n",
      "\n",
      "-------------------------43-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-628  ||  disease_of_miRNA = Focal Epithelial Hyperplasia\n",
      "Focal -->  [] \n",
      "\n",
      "Epithelial -->  [] \n",
      "\n",
      "Hyperplasia -->  [] \n",
      "\n",
      "-------------------------44-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-30a  ||  disease_of_miRNA = Focal Epithelial Hyperplasia\n",
      "Focal -->  [['hsa-mir-30a' nan 'Focal Segmental Glomerulosclerosis' nan]] \n",
      "\n",
      "Epithelial -->  [] \n",
      "\n",
      "Hyperplasia -->  [] \n",
      "\n",
      "-------------------------45-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-181c  ||  disease_of_miRNA = Fatty Liver\n",
      "Fatty -->  [] \n",
      "\n",
      "Liver -->  [] \n",
      "\n",
      "-------------------------46-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-423  ||  disease_of_miRNA = Endometriosis\n"
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "\r",
      " 74%|███████▎  | 50/68 [00:01<00:00, 35.78it/s]"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Endometriosis -->  [] \n",
      "\n",
      "-------------------------47-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-30c  ||  disease_of_miRNA = Encephalomyelitis, Autoimmune, Experimental\n",
      "Encephalomyelitis, -->  [] \n",
      "\n",
      "Autoimmune, -->  [] \n",
      "\n",
      "Experimental -->  [] \n",
      "\n",
      "-------------------------48-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-1293  ||  disease_of_miRNA = Digestive System Neoplasms\n",
      "Digestive -->  [] \n",
      "\n",
      "System -->  [] \n",
      "\n",
      "Neoplasms -->  [] \n",
      "\n",
      "-------------------------49-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-873  ||  disease_of_miRNA = Diabetic Retinopathy\n",
      "Diabetic -->  [] \n",
      "\n",
      "Retinopathy -->  [] \n",
      "\n",
      "-------------------------50-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-15b  ||  disease_of_miRNA = Diabetic Nephropathies\n",
      "Diabetic -->  [['hsa-mir-15b' nan 'Diabetic Nephropathy' nan]] \n",
      "\n",
      "Nephropathies -->  [] \n",
      "\n",
      "-------------------------51-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-143  ||  disease_of_miRNA = Colitis\n",
      "Colitis -->  [['hsa-mir-143' nan 'Colitis, Ulcerative' nan]] \n",
      "\n",
      "-------------------------52-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-100  ||  disease_of_miRNA = Cocaine-Related Disorders\n",
      "Cocaine-Related -->  [] \n",
      "\n",
      "Disorders -->  [['hsa-mir-100' nan 'Muscular Disorders, Atrophic' nan]] \n",
      "\n",
      "-------------------------53-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-425  ||  disease_of_miRNA = Child Development Disorders, Pervasive\n",
      "Child -->  [] \n",
      "\n",
      "Development -->  [] \n",
      "\n"
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      " 87%|████████▋ | 59/68 [00:01<00:00, 35.18it/s]"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Disorders, -->  [] \n",
      "\n",
      "Pervasive -->  [] \n",
      "\n",
      "-------------------------54-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-337  ||  disease_of_miRNA = Cervical Neoplasms\n",
      "Cervical -->  [['hsa-mir-337' nan 'Carcinoma, Cervical' nan]] \n",
      "\n",
      "Neoplasms -->  [['hsa-mir-337' nan 'Gastric Neoplasms' nan]\n",
      " ['hsa-mir-337' nan 'Salivary Gland Neoplasms' nan]\n",
      " ['hsa-mir-337' nan 'Colorectal Neoplasms' nan]] \n",
      "\n",
      "-------------------------55-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-625  ||  disease_of_miRNA = Central Nervous System Diseases\n",
      "Central -->  [] \n",
      "\n",
      "Nervous -->  [] \n",
      "\n",
      "System -->  [] \n",
      "\n",
      "Diseases -->  [] \n",
      "\n",
      "-------------------------56-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-655  ||  disease_of_miRNA = Carcinoma, Squamous Cell\n",
      "Carcinoma, -->  [['hsa-mir-655' nan 'Carcinoma, Renal Cell' nan]\n",
      " ['hsa-mir-655' nan 'Squamous Cell Carcinoma, Oral' nan]\n",
      " ['hsa-mir-655' nan 'Carcinoma, Hepatocellular' nan]\n",
      " ['hsa-mir-655' nan 'Squamous Cell Carcinoma, Esophageal' nan]] \n",
      "\n",
      "Squamous -->  [['hsa-mir-655' nan 'Squamous Cell Carcinoma, Oral' nan]\n",
      " ['hsa-mir-655' nan 'Squamous Cell Carcinoma, Esophageal' nan]] \n",
      "\n",
      "Cell -->  [['hsa-mir-655' nan 'Carcinoma, Renal Cell' nan]\n",
      " ['hsa-mir-655' nan 'Squamous Cell Carcinoma, Oral' nan]\n",
      " ['hsa-mir-655' nan 'Squamous Cell Carcinoma, Esophageal' nan]] \n",
      "\n",
      "-------------------------57-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-504  ||  disease_of_miRNA = Carcinoma, Neuroendocrine\n",
      "Carcinoma, -->  [['hsa-mir-504' nan 'Squamous Cell Carcinoma, Oral' nan]\n",
      " ['hsa-mir-504' nan\n",
      "  'Squamous Cell Carcinoma, Laryngeal or Hypopharyngeal' nan]\n",
      " ['hsa-mir-504' nan 'Carcinoma, Hepatocellular' nan]\n",
      " ['hsa-mir-504' nan 'Carcinoma, Nasopharyngeal' nan]\n",
      " ['hsa-mir-504' nan 'Carcinoma, Squamous Cell' nan]] \n",
      "\n",
      "Neuroendocrine -->  [] \n",
      "\n",
      "-------------------------58-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-154  ||  disease_of_miRNA = Burns\n",
      "Burns -->  [] \n",
      "\n",
      "-------------------------59-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-95  ||  disease_of_miRNA = Brain Ischemia\n",
      "Brain -->  [] \n",
      "\n",
      "Ischemia -->  [] \n",
      "\n",
      "-------------------------60-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-198  ||  disease_of_miRNA = Brain Injuries\n",
      "Brain -->  [] \n",
      "\n",
      "Injuries -->  [] \n",
      "\n",
      "-------------------------61-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-1285  ||  disease_of_miRNA = Asthma\n",
      "Asthma -->  [] \n",
      "\n",
      "-------------------------62-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-137  ||  disease_of_miRNA = Anemia, Sickle Cell\n",
      "Anemia, -->  [] \n",
      "\n",
      "Sickle -->  [] \n",
      "\n",
      "Cell -->  [['hsa-mir-137' nan 'Squamous Cell Carcinoma, Oral' nan]\n",
      " ['hsa-mir-137' nan 'Squamous Cell Carcinoma, Head and Neck' nan]\n",
      " ['hsa-mir-137' nan 'Carcinoma, Lung, Non-Small-Cell' nan]\n",
      " ['hsa-mir-137' nan 'Squamous Cell Carcinoma, Tongue' nan]\n",
      " ['hsa-mir-137' nan 'Carcinoma, Renal Cell' nan]\n",
      " ['hsa-mir-137' nan 'Carcinoma, Lung, Small-Cell' nan]\n",
      " ['hsa-mir-137' nan 'Carcinoma, Squamous Cell' nan]] \n",
      "\n",
      "-------------------------63-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-410  ||  disease_of_miRNA = Alzheimer Disease\n",
      "Alzheimer -->  [] \n",
      "\n",
      "Disease -->  [['hsa-mir-410' nan 'Pelvic Inflammatory Disease' nan]] \n",
      "\n",
      "-------------------------64-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-566  ||  disease_of_miRNA = Adrenocortical Adenoma\n"
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "100%|██████████| 68/68 [00:01<00:00, 36.35it/s]"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Adrenocortical -->  [] \n",
      "\n",
      "Adenoma -->  [] \n",
      "\n",
      "-------------------------65-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-181d  ||  disease_of_miRNA = Adenocarcinoma\n",
      "Adenocarcinoma -->  [] \n",
      "\n",
      "-------------------------66-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-451b  ||  disease_of_miRNA = Acute Lung Injury\n",
      "Acute -->  [] \n",
      "\n",
      "Lung -->  [['hsa-mir-451b' nan 'Carcinoma, Lung, Non-Small-Cell' nan]\n",
      " ['hsa-mir-451b' nan 'Carcinoma, Non-Small-Cell Lung' nan]] \n",
      "\n",
      "Injury -->  [] \n",
      "\n",
      "-------------------------67-th new MDA--------------------------------------------\n",
      "miRNA = hsa-mir-1273a  ||  disease_of_miRNA = Abortion, Habitual\n",
      "Abortion, -->  [] \n",
      "\n",
      "Habitual -->  [] \n",
      "\n"
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "\n"
     ]
    }
   ],
   "source": [
    "results_Td, new_MDA_Td, new_MDA_simplied_Td, database_data_miRNA_in_results_Td = run(task = 'Td', database_data = database_data)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {
    "collapsed": true
   },
   "source": [
    "# 整理"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 14,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>miRNA_x</th>\n",
       "      <th>disease_x</th>\n",
       "      <th>y_true</th>\n",
       "      <th>y_pred</th>\n",
       "      <th>y_prob</th>\n",
       "      <th>miRNA_y</th>\n",
       "      <th>disease_y</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>8048</th>\n",
       "      <td>116</td>\n",
       "      <td>383</td>\n",
       "      <td>1.0</td>\n",
       "      <td>1.0</td>\n",
       "      <td>0.999104</td>\n",
       "      <td>hsa-mir-483</td>\n",
       "      <td>['Wounds and Injuries']</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8049</th>\n",
       "      <td>9</td>\n",
       "      <td>383</td>\n",
       "      <td>1.0</td>\n",
       "      <td>1.0</td>\n",
       "      <td>0.999097</td>\n",
       "      <td>hsa-mir-143</td>\n",
       "      <td>['Wounds and Injuries']</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8037</th>\n",
       "      <td>148</td>\n",
       "      <td>383</td>\n",
       "      <td>1.0</td>\n",
       "      <td>1.0</td>\n",
       "      <td>0.999097</td>\n",
       "      <td>hsa-mir-9</td>\n",
       "      <td>['Wounds and Injuries']</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8036</th>\n",
       "      <td>14</td>\n",
       "      <td>383</td>\n",
       "      <td>1.0</td>\n",
       "      <td>1.0</td>\n",
       "      <td>0.999079</td>\n",
       "      <td>hsa-mir-21</td>\n",
       "      <td>['Wounds and Injuries']</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8034</th>\n",
       "      <td>10</td>\n",
       "      <td>383</td>\n",
       "      <td>1.0</td>\n",
       "      <td>1.0</td>\n",
       "      <td>0.998415</td>\n",
       "      <td>hsa-mir-145</td>\n",
       "      <td>['Wounds and Injuries']</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8554</th>\n",
       "      <td>482</td>\n",
       "      <td>1</td>\n",
       "      <td>0.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>0.001152</td>\n",
       "      <td>hsa-mir-570</td>\n",
       "      <td>['Abortion, Habitual']</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8543</th>\n",
       "      <td>24</td>\n",
       "      <td>1</td>\n",
       "      <td>0.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>0.001151</td>\n",
       "      <td>hsa-mir-126</td>\n",
       "      <td>['Abortion, Habitual']</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8551</th>\n",
       "      <td>164</td>\n",
       "      <td>1</td>\n",
       "      <td>0.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>0.001149</td>\n",
       "      <td>hsa-let-7i</td>\n",
       "      <td>['Abortion, Habitual']</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8553</th>\n",
       "      <td>454</td>\n",
       "      <td>1</td>\n",
       "      <td>0.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>0.001148</td>\n",
       "      <td>hsa-mir-767</td>\n",
       "      <td>['Abortion, Habitual']</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8552</th>\n",
       "      <td>63</td>\n",
       "      <td>1</td>\n",
       "      <td>0.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>0.001148</td>\n",
       "      <td>hsa-mir-1246</td>\n",
       "      <td>['Abortion, Habitual']</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>10860 rows × 7 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "      miRNA_x  disease_x  y_true  y_pred    y_prob       miRNA_y  \\\n",
       "8048      116        383     1.0     1.0  0.999104   hsa-mir-483   \n",
       "8049        9        383     1.0     1.0  0.999097   hsa-mir-143   \n",
       "8037      148        383     1.0     1.0  0.999097     hsa-mir-9   \n",
       "8036       14        383     1.0     1.0  0.999079    hsa-mir-21   \n",
       "8034       10        383     1.0     1.0  0.998415   hsa-mir-145   \n",
       "...       ...        ...     ...     ...       ...           ...   \n",
       "8554      482          1     0.0     0.0  0.001152   hsa-mir-570   \n",
       "8543       24          1     0.0     0.0  0.001151   hsa-mir-126   \n",
       "8551      164          1     0.0     0.0  0.001149    hsa-let-7i   \n",
       "8553      454          1     0.0     0.0  0.001148   hsa-mir-767   \n",
       "8552       63          1     0.0     0.0  0.001148  hsa-mir-1246   \n",
       "\n",
       "                    disease_y  \n",
       "8048  ['Wounds and Injuries']  \n",
       "8049  ['Wounds and Injuries']  \n",
       "8037  ['Wounds and Injuries']  \n",
       "8036  ['Wounds and Injuries']  \n",
       "8034  ['Wounds and Injuries']  \n",
       "...                       ...  \n",
       "8554   ['Abortion, Habitual']  \n",
       "8543   ['Abortion, Habitual']  \n",
       "8551   ['Abortion, Habitual']  \n",
       "8553   ['Abortion, Habitual']  \n",
       "8552   ['Abortion, Habitual']  \n",
       "\n",
       "[10860 rows x 7 columns]"
      ]
     },
     "execution_count": 14,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "results_Td"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 13,
   "metadata": {},
   "outputs": [
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "/home/chujunyi/anaconda3/envs/python36/lib/python3.6/site-packages/ipykernel_launcher.py:1: UserWarning: Boolean Series key will be reindexed to match DataFrame index.\n",
      "  \"\"\"Entry point for launching an IPython kernel.\n"
     ]
    },
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>miRNA_x</th>\n",
       "      <th>disease_x</th>\n",
       "      <th>y_true</th>\n",
       "      <th>y_pred</th>\n",
       "      <th>y_prob</th>\n",
       "      <th>miRNA_y</th>\n",
       "      <th>disease_y</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>8048</th>\n",
       "      <td>116</td>\n",
       "      <td>383</td>\n",
       "      <td>1.0</td>\n",
       "      <td>1.0</td>\n",
       "      <td>0.999104</td>\n",
       "      <td>hsa-mir-483</td>\n",
       "      <td>['Wounds and Injuries']</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8049</th>\n",
       "      <td>9</td>\n",
       "      <td>383</td>\n",
       "      <td>1.0</td>\n",
       "      <td>1.0</td>\n",
       "      <td>0.999097</td>\n",
       "      <td>hsa-mir-143</td>\n",
       "      <td>['Wounds and Injuries']</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8037</th>\n",
       "      <td>148</td>\n",
       "      <td>383</td>\n",
       "      <td>1.0</td>\n",
       "      <td>1.0</td>\n",
       "      <td>0.999097</td>\n",
       "      <td>hsa-mir-9</td>\n",
       "      <td>['Wounds and Injuries']</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8036</th>\n",
       "      <td>14</td>\n",
       "      <td>383</td>\n",
       "      <td>1.0</td>\n",
       "      <td>1.0</td>\n",
       "      <td>0.999079</td>\n",
       "      <td>hsa-mir-21</td>\n",
       "      <td>['Wounds and Injuries']</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8034</th>\n",
       "      <td>10</td>\n",
       "      <td>383</td>\n",
       "      <td>1.0</td>\n",
       "      <td>1.0</td>\n",
       "      <td>0.998415</td>\n",
       "      <td>hsa-mir-145</td>\n",
       "      <td>['Wounds and Injuries']</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3543</th>\n",
       "      <td>4</td>\n",
       "      <td>2</td>\n",
       "      <td>1.0</td>\n",
       "      <td>1.0</td>\n",
       "      <td>0.998640</td>\n",
       "      <td>hsa-mir-198</td>\n",
       "      <td>['Acquired Immunodeficiency Syndrome']</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3546</th>\n",
       "      <td>6</td>\n",
       "      <td>2</td>\n",
       "      <td>1.0</td>\n",
       "      <td>1.0</td>\n",
       "      <td>0.998612</td>\n",
       "      <td>hsa-mir-29b</td>\n",
       "      <td>['Acquired Immunodeficiency Syndrome']</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8537</th>\n",
       "      <td>2</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "      <td>1.0</td>\n",
       "      <td>0.999107</td>\n",
       "      <td>hsa-mir-196a</td>\n",
       "      <td>['Abortion, Habitual']</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8541</th>\n",
       "      <td>3</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "      <td>1.0</td>\n",
       "      <td>0.999105</td>\n",
       "      <td>hsa-mir-499a</td>\n",
       "      <td>['Abortion, Habitual']</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8549</th>\n",
       "      <td>1</td>\n",
       "      <td>1</td>\n",
       "      <td>1.0</td>\n",
       "      <td>1.0</td>\n",
       "      <td>0.999089</td>\n",
       "      <td>hsa-mir-125a</td>\n",
       "      <td>['Abortion, Habitual']</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>5297 rows × 7 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "      miRNA_x  disease_x  y_true  y_pred    y_prob       miRNA_y  \\\n",
       "8048      116        383     1.0     1.0  0.999104   hsa-mir-483   \n",
       "8049        9        383     1.0     1.0  0.999097   hsa-mir-143   \n",
       "8037      148        383     1.0     1.0  0.999097     hsa-mir-9   \n",
       "8036       14        383     1.0     1.0  0.999079    hsa-mir-21   \n",
       "8034       10        383     1.0     1.0  0.998415   hsa-mir-145   \n",
       "...       ...        ...     ...     ...       ...           ...   \n",
       "3543        4          2     1.0     1.0  0.998640   hsa-mir-198   \n",
       "3546        6          2     1.0     1.0  0.998612   hsa-mir-29b   \n",
       "8537        2          1     1.0     1.0  0.999107  hsa-mir-196a   \n",
       "8541        3          1     1.0     1.0  0.999105  hsa-mir-499a   \n",
       "8549        1          1     1.0     1.0  0.999089  hsa-mir-125a   \n",
       "\n",
       "                                   disease_y  \n",
       "8048                 ['Wounds and Injuries']  \n",
       "8049                 ['Wounds and Injuries']  \n",
       "8037                 ['Wounds and Injuries']  \n",
       "8036                 ['Wounds and Injuries']  \n",
       "8034                 ['Wounds and Injuries']  \n",
       "...                                      ...  \n",
       "3543  ['Acquired Immunodeficiency Syndrome']  \n",
       "3546  ['Acquired Immunodeficiency Syndrome']  \n",
       "8537                  ['Abortion, Habitual']  \n",
       "8541                  ['Abortion, Habitual']  \n",
       "8549                  ['Abortion, Habitual']  \n",
       "\n",
       "[5297 rows x 7 columns]"
      ]
     },
     "execution_count": 13,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "results_Td[results_Td['y_true'] == 1][results_Td['y_pred'] == 1]"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# Nouse"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 80,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>disease_newMDA</th>\n",
       "      <th>disease</th>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>miRNA_y</th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>hsa-mir-100</th>\n",
       "      <td>[Cocaine-Related Disorders]</td>\n",
       "      <td>[Carcinoma, Adrenocortical, Muscle Atrophy, At...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>hsa-mir-10b</th>\n",
       "      <td>[Sepsis]</td>\n",
       "      <td>[Breast Neoplasms, Leukemia, Huntington Diseas...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>hsa-mir-1181</th>\n",
       "      <td>[Oligodendroglioma]</td>\n",
       "      <td>[Hepatitis C Virus Infection, Pancreatic Neopl...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>hsa-mir-1245a</th>\n",
       "      <td>[Hepatitis]</td>\n",
       "      <td>[Breast Neoplasms]</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>hsa-mir-1273a</th>\n",
       "      <td>[Abortion, Habitual]</td>\n",
       "      <td>[Adenovirus Infection, Adenoviridae Infections]</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>hsa-mir-758</th>\n",
       "      <td>[Graft vs Host Disease]</td>\n",
       "      <td>[HELLP Syndrome, Systemic Lupus Erythematosus,...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>hsa-mir-769</th>\n",
       "      <td>[Mastocytosis, Systemic]</td>\n",
       "      <td>[Lupus Vulgaris, Squamous Cell Carcinoma, Oral...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>hsa-mir-873</th>\n",
       "      <td>[Diabetic Retinopathy]</td>\n",
       "      <td>[Ectopic Pregnancy, Liver Cirrhosis, Johne Dis...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>hsa-mir-922</th>\n",
       "      <td>[Nevus, Pigmented]</td>\n",
       "      <td>[Breast Neoplasms, Alzheimer Disease, Carcinom...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>hsa-mir-942</th>\n",
       "      <td>[Ischemia]</td>\n",
       "      <td>[Nephrotic Syndrome, Carcinoma, Breast, Kaposi...</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>75 rows × 2 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "                            disease_newMDA  \\\n",
       "miRNA_y                                      \n",
       "hsa-mir-100    [Cocaine-Related Disorders]   \n",
       "hsa-mir-10b                       [Sepsis]   \n",
       "hsa-mir-1181           [Oligodendroglioma]   \n",
       "hsa-mir-1245a                  [Hepatitis]   \n",
       "hsa-mir-1273a         [Abortion, Habitual]   \n",
       "...                                    ...   \n",
       "hsa-mir-758        [Graft vs Host Disease]   \n",
       "hsa-mir-769       [Mastocytosis, Systemic]   \n",
       "hsa-mir-873         [Diabetic Retinopathy]   \n",
       "hsa-mir-922             [Nevus, Pigmented]   \n",
       "hsa-mir-942                     [Ischemia]   \n",
       "\n",
       "                                                         disease  \n",
       "miRNA_y                                                           \n",
       "hsa-mir-100    [Carcinoma, Adrenocortical, Muscle Atrophy, At...  \n",
       "hsa-mir-10b    [Breast Neoplasms, Leukemia, Huntington Diseas...  \n",
       "hsa-mir-1181   [Hepatitis C Virus Infection, Pancreatic Neopl...  \n",
       "hsa-mir-1245a                                 [Breast Neoplasms]  \n",
       "hsa-mir-1273a    [Adenovirus Infection, Adenoviridae Infections]  \n",
       "...                                                          ...  \n",
       "hsa-mir-758    [HELLP Syndrome, Systemic Lupus Erythematosus,...  \n",
       "hsa-mir-769    [Lupus Vulgaris, Squamous Cell Carcinoma, Oral...  \n",
       "hsa-mir-873    [Ectopic Pregnancy, Liver Cirrhosis, Johne Dis...  \n",
       "hsa-mir-922    [Breast Neoplasms, Alzheimer Disease, Carcinom...  \n",
       "hsa-mir-942    [Nephrotic Syndrome, Carcinoma, Breast, Kaposi...  \n",
       "\n",
       "[75 rows x 2 columns]"
      ]
     },
     "execution_count": 80,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "new_MDA_Tp_balanced_simplied_2 = pd.DataFrame(new_MDA_Tp_balanced_simplied.groupby('miRNA_y')['disease_newMDA'].apply(list))\n",
    "database_data_miRNA_in_Tp_balanced_simplied = pd.DataFrame(database_data_miRNA_in_Tp_balanced.groupby('miRNA')['disease'].apply(list))\n",
    "new_MDA_Tp_balanced__database_data__merged = pd.merge(new_MDA_Tp_balanced_simplied_2, database_data_miRNA_in_Tp_balanced_simplied, left_index = True, right_index = True)\n",
    "new_MDA_Tp_balanced__database_data__merged"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 81,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "miRNA_y\n",
       "hsa-mir-100      [Cocaine-Related Disorders]\n",
       "hsa-mir-10b                         [Sepsis]\n",
       "hsa-mir-1181             [Oligodendroglioma]\n",
       "hsa-mir-1245a                    [Hepatitis]\n",
       "hsa-mir-1273a           [Abortion, Habitual]\n",
       "                            ...             \n",
       "hsa-mir-758          [Graft vs Host Disease]\n",
       "hsa-mir-769         [Mastocytosis, Systemic]\n",
       "hsa-mir-873           [Diabetic Retinopathy]\n",
       "hsa-mir-922               [Nevus, Pigmented]\n",
       "hsa-mir-942                       [Ischemia]\n",
       "Name: disease_newMDA, Length: 75, dtype: object"
      ]
     },
     "execution_count": 81,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "new_MDA_table = new_MDA_Tp_balanced__database_data__merged['disease_newMDA']\n",
    "database_data_table = new_MDA_Tp_balanced__database_data__merged['disease']\n",
    "new_MDA_table"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 133,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "array([['Muscular Disorders, Atrophic']], dtype=object)"
      ]
     },
     "execution_count": 133,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "temp.loc[temp[0].str.contains(s)].values"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 111,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Cocaine-Related\n",
      "Empty DataFrame\n",
      "Columns: [0]\n",
      "Index: []\n",
      "Disorders\n",
      "                               0\n",
      "66  Muscular Disorders, Atrophic\n"
     ]
    }
   ],
   "source": [
    "newMDA_disease = new_MDA_table[0][0].split(' ')\n",
    "temp = pd.DataFrame(database_data_table[0])\n",
    "for s in newMDA_disease:\n",
    "    print(s)\n",
    "    print(temp.loc[temp[0].str.contains(s)])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 94,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "'Carcinoma, Adrenocortical,Muscle Atrophy,Atherosclerosis,Adrenal Cortex Neoplasms,Breast Neoplasms,Acute Coronary Syndrome,Coronary Atherosclerosis,Diabetes Mellitus, Type 1,Esophageal Neoplasms,Recurrent Spontaneous Abortion,Leukemia-Lymphoma, Precursor T-Cell Lymphoblastic,Carcinoma, Lung, Non-Small-Cell,Squamous Cell Carcinoma, Esophageal,Urinary Bladder Cancer,Carcinoma, Hepatocellular,Bladder Neoplasms,Gastric Neoplasms,Leukemia, Myeloid, Acute,Prostate Neoplasms,Carcinoma, Renal Cell,Ovarian Neoplasms,Osteosarcoma,Heart Failure,Leukemia, Lymphoblastic, Acute,Vulvar Squamous Cell Carcinoma,Neoplasms [unspecific],Pancreatic Neoplasms,Cardiovascular Diseases [unspecific],Colorectal Carcinoma,Inflammation,Carcinoma, Rectal,Peritoneal Dialysis Failure,Vascular Injuries,Carcinoma, Ovarian,Infection [unspecific],Carcinoma, Bladder,Carcinoma, Gastric,Squamous Cell Carcinoma, Head and Neck,Melanoma,Carcinoma, Colon,Pneumonia,Nasopharyngeal Neoplasms,Endometrial Neoplasms,Lung Neoplasms,Kaposi Sarcoma,Glioblastoma,Chondrosarcoma,Alzheimer Disease,IgA Nephropathy,Carcinoma, Breast,Thyroid Neoplasms,Heart Diseases [unspecific],Carotid Atherosclerosis,Adenocarcinoma, Gastric,Adenocarcinoma, Pancreatic Ductal,Multiple Sclerosis,Carcinoma, Cervical,Head And Neck Neoplasms,Carcinoma, Lung, Small-Cell,Chronic Obstructive Pulmonary Disease,Squamous Cell Carcinoma, Oral,Psoriasis,Periodontitis,Carcinoma, Urothelial,Endometriosis,Muscular Dystrophy,Muscular Disorders, Atrophic,Adrenocortical Carcinoma,Stomach Neoplasms,Prostatic Neoplasms,Precursor Cell Lymphoblastic Leukemia-Lymphoma,Head and Neck Neoplasms,Carcinoma, Squamous Cell,Uterine Cervical Neoplasms,Muscular Dystrophies,Carcinoma, Small Cell,Urinary Bladder Neoplasms,Pulmonary Disease, Chronic Obstructive,Carcinoma, Non-Small-Cell Lung'"
      ]
     },
     "execution_count": 94,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "database_disease = ','.join(database_data_table[0])\n",
    "database_disease"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 90,
   "metadata": {
    "collapsed": true
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Cocaine-Related Disorders \t Carcinoma, Adrenocortical\n",
      "Cocaine-Related Disorders \t Muscle Atrophy\n",
      "Cocaine-Related Disorders \t Atherosclerosis\n",
      "Cocaine-Related Disorders \t Adrenal Cortex Neoplasms\n",
      "Cocaine-Related Disorders \t Breast Neoplasms\n",
      "Cocaine-Related Disorders \t Acute Coronary Syndrome\n",
      "Cocaine-Related Disorders \t Coronary Atherosclerosis\n",
      "Cocaine-Related Disorders \t Diabetes Mellitus, Type 1\n",
      "Cocaine-Related Disorders \t Esophageal Neoplasms\n",
      "Cocaine-Related Disorders \t Recurrent Spontaneous Abortion\n",
      "Cocaine-Related Disorders \t Leukemia-Lymphoma, Precursor T-Cell Lymphoblastic\n",
      "Cocaine-Related Disorders \t Carcinoma, Lung, Non-Small-Cell\n",
      "Cocaine-Related Disorders \t Squamous Cell Carcinoma, Esophageal\n",
      "Cocaine-Related Disorders \t Urinary Bladder Cancer\n",
      "Cocaine-Related Disorders \t Carcinoma, Hepatocellular\n",
      "Cocaine-Related Disorders \t Bladder Neoplasms\n",
      "Cocaine-Related Disorders \t Gastric Neoplasms\n",
      "Cocaine-Related Disorders \t Leukemia, Myeloid, Acute\n",
      "Cocaine-Related Disorders \t Prostate Neoplasms\n",
      "Cocaine-Related Disorders \t Carcinoma, Renal Cell\n",
      "Cocaine-Related Disorders \t Ovarian Neoplasms\n",
      "Cocaine-Related Disorders \t Osteosarcoma\n",
      "Cocaine-Related Disorders \t Heart Failure\n",
      "Cocaine-Related Disorders \t Leukemia, Lymphoblastic, Acute\n",
      "Cocaine-Related Disorders \t Vulvar Squamous Cell Carcinoma\n",
      "Cocaine-Related Disorders \t Neoplasms [unspecific]\n",
      "Cocaine-Related Disorders \t Pancreatic Neoplasms\n",
      "Cocaine-Related Disorders \t Cardiovascular Diseases [unspecific]\n",
      "Cocaine-Related Disorders \t Colorectal Carcinoma\n",
      "Cocaine-Related Disorders \t Inflammation\n",
      "Cocaine-Related Disorders \t Carcinoma, Rectal\n",
      "Cocaine-Related Disorders \t Peritoneal Dialysis Failure\n",
      "Cocaine-Related Disorders \t Vascular Injuries\n",
      "Cocaine-Related Disorders \t Carcinoma, Ovarian\n",
      "Cocaine-Related Disorders \t Infection [unspecific]\n",
      "Cocaine-Related Disorders \t Carcinoma, Bladder\n",
      "Cocaine-Related Disorders \t Carcinoma, Gastric\n",
      "Cocaine-Related Disorders \t Squamous Cell Carcinoma, Head and Neck\n",
      "Cocaine-Related Disorders \t Melanoma\n",
      "Cocaine-Related Disorders \t Carcinoma, Colon\n",
      "Cocaine-Related Disorders \t Pneumonia\n",
      "Cocaine-Related Disorders \t Nasopharyngeal Neoplasms\n",
      "Cocaine-Related Disorders \t Endometrial Neoplasms\n",
      "Cocaine-Related Disorders \t Lung Neoplasms\n",
      "Cocaine-Related Disorders \t Kaposi Sarcoma\n",
      "Cocaine-Related Disorders \t Glioblastoma\n",
      "Cocaine-Related Disorders \t Chondrosarcoma\n",
      "Cocaine-Related Disorders \t Alzheimer Disease\n",
      "Cocaine-Related Disorders \t IgA Nephropathy\n",
      "Cocaine-Related Disorders \t Carcinoma, Breast\n",
      "Cocaine-Related Disorders \t Thyroid Neoplasms\n",
      "Cocaine-Related Disorders \t Heart Diseases [unspecific]\n",
      "Cocaine-Related Disorders \t Carotid Atherosclerosis\n",
      "Cocaine-Related Disorders \t Adenocarcinoma, Gastric\n",
      "Cocaine-Related Disorders \t Adenocarcinoma, Pancreatic Ductal\n",
      "Cocaine-Related Disorders \t Multiple Sclerosis\n",
      "Cocaine-Related Disorders \t Carcinoma, Cervical\n",
      "Cocaine-Related Disorders \t Head And Neck Neoplasms\n",
      "Cocaine-Related Disorders \t Carcinoma, Lung, Small-Cell\n",
      "Cocaine-Related Disorders \t Chronic Obstructive Pulmonary Disease\n",
      "Cocaine-Related Disorders \t Squamous Cell Carcinoma, Oral\n",
      "Cocaine-Related Disorders \t Psoriasis\n",
      "Cocaine-Related Disorders \t Periodontitis\n",
      "Cocaine-Related Disorders \t Carcinoma, Urothelial\n",
      "Cocaine-Related Disorders \t Endometriosis\n",
      "Cocaine-Related Disorders \t Muscular Dystrophy\n",
      "Cocaine-Related Disorders \t Muscular Disorders, Atrophic\n",
      "Cocaine-Related Disorders \t Adrenocortical Carcinoma\n",
      "Cocaine-Related Disorders \t Stomach Neoplasms\n",
      "Cocaine-Related Disorders \t Prostatic Neoplasms\n",
      "Cocaine-Related Disorders \t Precursor Cell Lymphoblastic Leukemia-Lymphoma\n",
      "Cocaine-Related Disorders \t Head and Neck Neoplasms\n",
      "Cocaine-Related Disorders \t Carcinoma, Squamous Cell\n",
      "Cocaine-Related Disorders \t Uterine Cervical Neoplasms\n",
      "Cocaine-Related Disorders \t Muscular Dystrophies\n",
      "Cocaine-Related Disorders \t Carcinoma, Small Cell\n",
      "Cocaine-Related Disorders \t Urinary Bladder Neoplasms\n",
      "Cocaine-Related Disorders \t Pulmonary Disease, Chronic Obstructive\n",
      "Cocaine-Related Disorders \t Carcinoma, Non-Small-Cell Lung\n"
     ]
    }
   ],
   "source": [
    "for i in range(len(new_MDA_table[0])):\n",
    "    for j in range(len(database_data_table[0])):\n",
    "        a = new_MDA_table[0][i]\n",
    "        b = database_data_table[0][j]\n",
    "        temp = re.findall(a, b)\n",
    "        print(a, '\\t', b)"
   ]
  }
 ],
 "metadata": {
  "anaconda-cloud": {},
  "kernelspec": {
   "display_name": "Python 3 (ipykernel)",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.7.15"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 1
}
